using System;
using System.Data.Entity.ModelConfiguration;
using System.Data.Common;
using System.Data.Entity;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using HISModels.Entities;

namespace HISModels.Mapping
{
	public class PriceListMap : EntityTypeConfiguration<PriceList>
	{
		public PriceListMap()
		{
			// Primary Key
			this.HasKey(t => t.Id);

			// Properties
			this.Property(t => t.ChargeName)
				.HasMaxLength(225);
				
			// Table & Column Mappings
			this.ToTable("PriceList");
			this.Property(t => t.Id).HasColumnName("Id");
			this.Property(t => t.ChargeName).HasColumnName("ChargeName");
			this.Property(t => t.RecordStatus).HasColumnName("RecordStatus");
			this.Property(t => t.RatePrice).HasColumnName("RatePrice");
			this.Property(t => t.EditPrice).HasColumnName("EditPrice");
			this.Property(t => t.ChargeTypeId).HasColumnName("ChargeTypeId");
			this.Property(t => t.BurdenRate).HasColumnName("BurdenRate");
			this.Property(t => t.Discontinued).HasColumnName("Discontinued");
		}
	}
}

